The present invention relates generally to the field of virtual machines, and more particularly to removing the initialization check in just-in-time (JIT) code per tenant in a multitenant virtual machine through controlled tenant bootstrap.
In computing, a virtual machine (VM) is an emulation of a particular computer system. Virtual machines operate based on the computer architecture and functions of a real or hypothetical computer, and the virtual machine's implementations may involve specialized hardware, software, or a combination of both. Classification of virtual machines can be based on the degree to which the virtual machine implements functionality of targeted real machines. System virtual machines (also known as full virtualization virtual machines) provide a complete substitute for the targeted real machine, and level of functionality required for the execution of a complete operating system. On the other hand, process virtual machines are designed to execute a single computer program by providing an abstracted and platform-independent program execution environment.
Just-in-time (JIT) compilation, also known as dynamic translation, is compilation done during execution of a program at run time, rather than prior to execution. Most often, the compilation consists of translation to machine code, which is then executed directly, but can also refer to translation to another format.
JIT compilation is a combination of the two traditional approaches of translation to machine code—ahead of time (AOT) compilation and interpretation—and combines some advantages and drawbacks of both. JIT compilation combines the speed of compiled code with the flexibility of interpretation, along with the overhead of an interpreter and the additional overhead of compiling (not just interpreting). JIT compilation is a form of dynamic compilation, and allows adaptive optimization, such as dynamic recompilation. Thus, in principle, JIT compilation can yield faster execution than static compilation. Interpretation and JIT compilation are particularly suited for dynamic programming languages, as the runtime system can handle late-bound data types and enforce security guarantees.
In computer programming, initialization is the assignment of an initial value for a data object or variable. The manner in which initialization is performed depends on programming language, as well as type, storage, class, etc., of an object to be initialized. Programming constructs which perform initialization are typically called initializers and initializer lists. Initialization is distinct from, and preceded by, declaration, although the two can sometimes be conflated in practice. The compliment of initialization is finalization, which is primarily used for objects, but not variables.
Initialization is done either by statically embedding the value at compile time, or else by assignment at run time. A section of code that performs such initialization is generally known as initialization code and may include other one-time-only functions, such as opening files. In object-oriented programming, initialization code may be part of a constructor (class method) or initializer (instance method). Setting a memory location to hexadecimal zeroes is also sometimes known as “clearing” and is often performed by an exclusive “or” instruction (both operands specifying the same variable) at machine code level, requiring no additional memory access.